<template>
  <!-- <h1>申报审批管理详情页4</h1> -->
  <div>
    <div class="w-label">
      <el-breadcrumb
        style="font-size: 20px; line-height: 50px"
        separator-class="el-icon-arrow-right"
      >
        <el-breadcrumb-item
          style="color: ##606266"
          :to="{ path: '/Company/TalentManagement' }"
          ><i class="el-icon-back"></i>待我审批的</el-breadcrumb-item
        >
        <el-breadcrumb-item
          ><a href="javascript:void(0)">详情</a></el-breadcrumb-item
        >
      </el-breadcrumb>
    </div>
    <div>
      <p>选择迁出人员</p>
    <el-tabs
      v-model="activeName"
      type="card"
      @tab-click="handleClick"
      style="margin-bottom: 0px"
    >
      <el-tab-pane label="迁出" name="first">
        <div class="sousuokuang">
          <el-form  ref="form" :model="sizeForm" label-width="80px" size="mini">
            <el-input
              v-model="sizeForm.name"
              placeholder="专技人员名称"
            ></el-input>
            <el-input
              v-model="sizeForm.num"
              placeholder="证件号码"
            ></el-input>
           <div
              class="block"
              style="width: 200px; display: inline-block; text-align: center"
            >
              <span class="demonstration"></span>
              <el-date-picker
                v-model="value1"
                type="datetimerange"
                range-separator="至"
                start-placeholder="开始日期"
                end-placeholder="结束日期"
              >
              </el-date-picker>
            </div>
            <el-form-item size="large">
              <el-button type="primary" @click="onquery">查询</el-button>
              <el-button>重置</el-button>
            </el-form-item>
          </el-form>
        </div>
        <div class="xianshi">
          <div style="margin: 5px 5px">
            <el-table
              ref="multipleTable"
              :data="tableData"
              tooltip-effect="dark"
              border
              style="width: 100%"
              @selection-change="handleSelectionChange"
            >
              <el-table-column type="selection" width="50"> </el-table-column>
              <el-table-column prop="sponsornum" label="编号" width="50">
              </el-table-column>
              <el-table-column prop="sponsortime" label="发起时间">
              </el-table-column>
              <el-table-column prop="sponsorinformation" label="发起人信息">
              </el-table-column>
              <el-table-column prop="sponsorsex" label="迁往单位名称" >
              </el-table-column>
              <el-table-column label="操作" width="240">
                <template>
                  <el-button type="text" size="medium" @click="choose"
                    >选择</el-button
                  >
                </template>
              </el-table-column>
            </el-table>
          </div>
        </div>
      </el-tab-pane>
    </el-tabs>
    </div>
    <div class="xuanze">
      <p>选择迁出单位</p>
      <el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
  <el-form-item  label="单位地区" prop="region">
    <el-select style="width:150px;margin:0;" v-model="ruleForm.region" placeholder="请选择区域">
      <el-option label="区域一" value="shanghai"></el-option>
      <el-option label="区域二" value="beijing"></el-option>
    </el-select> 
    </el-form-item>
    <el-form-item  label="单位名称" prop="name">
    <el-input v-model="ruleForm.name"></el-input>
  </el-form-item>
  <el-form-item label="迁出说明" prop="explain">
    <el-input v-model="ruleForm.name"></el-input>
  </el-form-item>
    <el-button type="primary" @click="submitForm('ruleForm')">确认提交</el-button>
  
</el-form>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      activeName: "first",
      ruleForm: {
        name: "",
        region: "",
        date1: "",
        date2: "",
        delivery: false,
        type: [],
        resource: "",
        desc: "",
      },
      sizeForm: {
        name: "",
        num: "",
        name1: "",
        num1: "",
        region1: "",
        region2: "",
      },
      value: "",
      value1: "",
      rules: {
        name: [
          { required: true, message: "请输入地区名称", trigger: "blur" },
          { min: 2, max: 20, message: "长度在 2 到 20 个字符", trigger: "blur" },
        ],
        region: [
          { required: true, message: "请选择区域", trigger: "change" },
        ],
        explain: [{ required: true, message: "请输入内容", trigger: "blur" }],
      },
      tableData: [
        {
          sponsornum: "1",
          sponsortime: "2016-05-02",
          sponsorinformation: "王小虎",
          sponsorsex: "男",
          sponsorinformation: "上海市普陀区金沙江路 1518 弄",
          sponsorseries: "社会工作者",
          sponsorspecialized: "社会学",
          sponsorsname: "助理社会工程师",
          sponsortype: "审核中",
        },
        {
          sponsornum: "1",
          sponsortime: "2016-05-02",
          sponsorinformation: "王小虎",
          sponsorsex: "男",
          sponsorinformation: "上海市普陀区金沙江路 1518 弄",
          sponsorseries: "社会工作者",
          sponsorspecialized: "社会学",
          sponsorsname: "助理社会工程师",
          sponsortype: "审核中",
        },
        {
          sponsornum: "1",
          sponsortime: "2016-05-02",
          sponsorinformation: "王小虎",
          sponsorsex: "男",
          sponsorinformation: "上海市普陀区金沙江路 1518 弄",
          sponsorseries: "社会工作者",
          sponsorspecialized: "社会学",
          sponsorsname: "助理社会工程师",
          sponsortype: "审核中",
        },
        {
          sponsornum: "1",
          sponsortime: "2016-05-02",
          sponsorinformation: "王小虎",
          sponsorsex: "男",
          sponsorinformation: "上海市普陀区金沙江路 1518 弄",
          sponsorseries: "社会工作者",
          sponsorspecialized: "社会学",
          sponsorsname: "助理社会工程师",
          sponsortype: "审核中",
        },
      ],
    };
  },
  methods: {
    submitForm(formName) {
      this.$refs[formName].validate((valid) => {
        if (valid) {
          alert("提交成功!");
        } else {
          console.log("error submit!!");
          return false;
        }
      });
    },
    handleClick(tab, event) {
      console.log(tab, event);
    },
    onquery() {
      console.log("正在查询!");
    },
    resetForm(formName) {
      this.$refs[formName].resetFields();
    },
    handleSelectionChange(val) {
      this.multipleSelection = val;
    },
    choose(){}
  },
  mounted(){
    sessionStorage.setItem('fName','TalentmangerOut')
  }
};
</script>

<style lang="less" scoped>
* {
  padding: 0;
  margin: 0;
}
.w-label {
  width: 100%;
  height: 50px;
  background-color: rgba(242, 242, 242, 1);
}
.xuanze{
  margin: 0 auto;
  width: 25%;
text-align: center;
}
.xuanze>.el-input {
  margin: 0;
}
button {
  width: 50px;
  height: 30px;
}
.el-button {
  width: 60px;
  height: 28px;
  font: size 28px;
}
.el-select {
  margin: 8px 18px 8px;
  text-align: left;
}
.el-input {
  width: 150px;
  height: 30px;
  margin: 8px 18px 8px;
  text-align: left;
}
body,
html,
#app,
el-aside {
  height: 100%;
}
.InternalNavigation {
  margin: 0px;
  width: 100%;
  height: 50px;
  background-color: rgba(242, 242, 242, 1);
}
.xianshi {
  margin: 0px;
  width: 100%;
  height: 100%;
  background-color: rgba(242, 242, 242, 1);
}
.shenheshauxin {
  height: 100%;
  width: 100%;
}
.sousuokuang {
  width: 100%;
  height: 126px;
  background-color: rgba(242, 242, 242, 0.5);
}
.el-container,
.el-menu {
  height: 100%;
}

.el-aside {
  background-color: #d3dce6;
  color: #333;
  text-align: center;
  line-height: 200px;
}

.el-main {
  background-color: #ffffff;
  color: #333;
  line-height: 20px;
  margin: 5px 20px 5px;
}

body > .el-container {
  margin-bottom: 40px;
}

.el-container:nth-child(5) .el-aside,
.el-container:nth-child(6) .el-aside {
  line-height: 260px;
}

.el-container:nth-child(7) .el-aside {
  line-height: 320px;
}
</style>